import fly from '@/utils/request'
import URL from '@/utils/host'
// 首页
export function myinfo(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/info',
        params: data
    })
}
// 粉丝
export function myfans(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/fans',
        params: data
    })
}
export function guanzhu(id,data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/guanzhu/'+id,
        params: data
    })
}
// 钱包
export function mywallet(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/wallet',
        params: data
    })
}

export function walletlist(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/wallet/log',
        params: data
    })
}

export function jifenlist(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/wallet/jifen/list',
        params: data
    })
}

export function cashjilu(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/wallet/cashlist',
        params: data
    })
}

export function getcash(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/wallet/tixian',
        params: data
    })
}

export function postcash(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/wallet/tixian',
        body: data
    })
}

// 订单
export function myorder(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/order',
        params: data
    })
}
export function orderdetail(id,data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/order/info/'+id,
        params: data
    })
}

export function ordertui(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/order/refund',
        body: data
    })
}

export function orderpingjia(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/order/evaluation',
        params: data
    })
}
export function orderpingjia1(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/order/evaluation',
        body: data
    })
}
export function orderOther(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/order/others',
        params: data
    })
}

// 资料编辑
export function setinfo(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/phone',
        body: data
    })
}
export function setnickname(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/nickname',
        params: data
    })
}
export function setage(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/age',
        params: data
    })
}
export function setgender(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/gender',
        params: data
    })
}
export function setbrief(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/brief',
        params: data
    })
}
export function setclass(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/class',
        params: data
    })
}
export function setarea(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/area',
        params: data
    })
}
export function setavatar(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/avatar',
        params: data
    })
}
export function gettag(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'tags',
        params: data
    })
}

// 收藏

export function getcoll(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/collection',
        params: data
    })
}


// 认证

export function renzheng(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/auth',
        body: data
    })
}
export function getrenzheng(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/auth/info',
        params: data
    })
}

// 发短信
export function sendmsg(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'sms',
        params: data
    })
}


//成为合伙人
// 列表
export function pataner(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/partner/all',
        params: data
    })
}
// 
export function patanerinfo(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/partner/info',
        params: data
    })
}
export function patanerbuy(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/partner/buy',
        body: data
    })
}
//客服

export function kefu(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'kefu',
        params: data
    })
}

//标签

export function gettags(data){
    return fly.request({
        method: 'get', 
        url:URL.host2+'user/tags',
        params: data
    })
}
export function posttags(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/tags',
        body: data
    })
}
//标签

export function password(data){
    return fly.request({
        method: 'post', 
        url:URL.host2+'user/pay_pass',
        body: data
    })
}